# -*- coding: utf-8 -*-

"""
    ESD
    ~~~

    Implements ESD setup

    sudo python setup.py sdist bdist_wheel
    sudo twine upload dist/ESD-0.0.x

    :author:    Feei <feei@feei.cn>
    :homepage:  https://github.com/FeeiCN/ESD
    :license:   GPL, see LICENSE for more details.
    :copyright: Copyright (c) 2018 Feei. All rights reserved
"""
import os
import setuptools
from ESD import __version__

# 指定文件编码, 避免中文或其他特殊字符乱码
with open('README.md', 'r', encoding='utf-8') as f:
    long_description = f.read()

# 指定项目运行所需的依赖包
install_requires = [
    'colorlog',
    'aiodns',
    'aiohttp',
    'async-timeout',
    'requests',
    'backoff',
    'dnspython',
    'pysocks',
    'tqdm',
    'colorama',
]

# 在Windows系统上自动添加pywin32依赖包
if os.name == 'nt':
    install_requires.append('pywin32>=300')

setuptools.setup(
    name='ESD',
    version=__version__,
    author='Feei',
    author_email='feei@feei.cn',
    description='Enumeration Sub Domains(枚举子域名)',
    long_description=long_description,
    long_description_content_type='text/markdown',
    url='https://github.com/FeeiCN/ESD',
    packages=setuptools.find_packages(),
    install_requires=install_requires,
    classifiers=[
        "Topic :: Security",
        "Programming Language :: Python :: 3",
        "License :: OSI Approved :: GNU General Public License v3 (GPLv3)"
    ],
    package_data={
        'ESD': ['subs.esd', 'subs-test.esd', 'cacert.pem']
    },
    include_package_data=True,
    entry_points={
        'console_scripts': [
            'esd=ESD:main'
        ]
    }
)